package lumis.portal.fileparser;

import java.io.File;

import lumis.portal.PortalException;

/**
 * Parses a file.
 *
 * @version $Revision: 13093 $ $Date: 2011-05-28 18:40:18 -0300 (Sat, 28 May 2011) $
 * @since 6.0.0
 */
public interface IFileParser
{
	/**
	 * Extracts the metadata of a file. This method should store the
	 * extracted metadata in the <code>metadata</code> parameter.
	 * @param file The file to be parsed.
	 * @param contentType The type of the content of the file.
	 * @param metadata The metadata already extracted.
	 * @throws PortalException If any error occurs extracting the metadata.
	 * @since 6.0.0
	 */
	void extractMetadata(File file, String contentType, FileMetadata metadata) throws PortalException;
}
